package com.neusoft.zqygbc.neusoft_wenda.view;

/**
 * Created by Shinelon on 2017/5/26.
 */

public enum SwipyRefreshLayoutDirection {

    TOP(0), // 只有下拉刷新
    BOTTOM(1), // 只有加载更多
    BOTH(2);// 全都有

    private int mValue;

    SwipyRefreshLayoutDirection(int value) {
        this.mValue = value;
    }

    public static SwipyRefreshLayoutDirection getFromInt(int value) {
        for (SwipyRefreshLayoutDirection direction : SwipyRefreshLayoutDirection
                .values()) {
            if (direction.mValue == value) {
                return direction;
            }
        }
        return BOTH;
    }

}
